﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;

namespace Hands.UriRewrite
{
    internal class RegularExpressionsRule
    {
        //internal const string PARSING_CONFIG_RAW_URI = "(https://)?(http://)?([a-z0-9]*\\.)+(com)*(org)*(cn)*(net)*(\\.cn)?(/+)([a-zA-Z0-9]+)+";
        internal readonly static Regex PARSING_CONFIG_URI_BRANCH_REGEX = new Regex("(/[a-zA-Z0-9]+)+", RegexOptions.Compiled);
        internal readonly static Regex PARSING_CONFIG_URI_HOST_REGEX = new Regex("(https://)?(http://)?([a-z0-9]*\\.)+(com)?(org)?(cn)?(net)?(\\.cn)?", RegexOptions.Compiled);
        internal readonly static Regex PARSING_CONFIG_URI_PARA_REGEX = new Regex("(?<para>{[a-zA-Z]+})", RegexOptions.Compiled);
        internal readonly static Regex PARSING_PARA_VALUE_REGEX = new Regex("(?<=/)[a-zA-Z0-9?\\.&=_]*", RegexOptions.Compiled);
    }
}
